import Vue from 'vue'
import VueRouter from 'vue-router'

import main from '../components/main.vue'
import device from '../components/service/device.vue'
import screen from '../components/service/screen.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    component: main,
    children: [
      {
        path: '/',
        redirect: 'device'
      },
      {
        path: 'device',
        component: device
      },
      {
        path: 'screen',
        component: screen
      }
    ]
  }
]

export default new VueRouter({
  routes
})